
		<div class="ui-portlet">
			{{template app_forums/_user_apps}}
			<ol class="breadcrumb">
			  <li><a href="/users/index"><i class="fa fa-home"></i>&nbsp;&nbsp;135公众平台</a></li>
			  <li class="active">管理社区论坛版块</li>
			  
			</ol> 
		</div>          
       <hr>

<style>
.bs-navbar-preview .nav > li > a  {padding:10px 10px;}
.bs-navbar-preview .navbar-nav {float:none;}
.navbar-fixed-bottom .navbar-nav > li > .dropdown-menu{
	min-width: 100%;
    width: 100%;
}
.bs-navbar-preview .nav > li {border-right:1px solid #ddd;}
.bs-navbar-preview .nav > li:last-child{border-right:0 none;}
.text-danger {
    color: #f00;
}
</style>       

   <div>
       <a class="btn btn-primary" href="{{$this->Html->url(array('action'=>'add'))}}?app_id={{$app_id}}">新增论坛版块</a>
   </div>
   
   <table class="ui-portlet table table-striped table-hover">
    <thead><tr><th>标题图片</th> <th>论坛名称</th> <th>显示</th> <th>描述</th> <th>操作</th></tr></thead>
    <tbody>
    {{loop $datalist $item}}
    <tr>
    	<td><a href="/app_forums/view/{{$item['AppForum']['id']}}?app_id={{$app_id}}">{{$this->Html->image($item['AppForum']['coverimg'],array('style'=>'width:80px;'))}}</a></td>
    	<td><a href="/app_forums/view/{{$item['AppForum']['id']}}?app_id={{$app_id}}">{{$item['AppForum']['name']}}</a></td>
    	<td>{{$item['AppForum']['visible']?'是':'否'}}</td>
    	<td>{{$item['AppForum']['summary']}}</td>
    	<td>
    		<a href="/app_forums/edit/{{$item['AppForum']['id']}}?app_id={{$app_id}}">编辑</a> &nbsp;
    		<a href="/app_forums/delete/{{$item['AppForum']['id']}}?app_id={{$app_id}}" onclick="return confirm('是否确认删除');">删除</a> 
    	</td>
    </tr>
    
    	{{if !empty($item['children'])}}
    		{{loop $item['children'] $sec_item}}
			    <tr>
			    	<td>&nbsp;&nbsp;&nbsp;&nbsp;<a target="_blank" href="/app_forums/view/{{$sec_item['AppForum']['id']}}?app_id={{$app_id}}">{{$this->Html->image($sec_item['AppForum']['coverimg'],array('style'=>'width:50px;'))}}</a></td>
			    	<td>----<a target="_blank" href="/app_forums/view/{{$sec_item['AppForum']['id']}}?app_id={{$app_id}}">{{$sec_item['AppForum']['name']}}</a></td>
			    	<td>{{$sec_item['AppForum']['visible']?'是':'否'}}</td>
			    	<td>{{$sec_item['AppForum']['summary']}}</td>
			    	<td>
			    		<a href="/app_forums/edit/{{$sec_item['AppForum']['id']}}?app_id={{$app_id}}">编辑</a> &nbsp;
			    		<a href="/app_forums/delete/{{$sec_item['AppForum']['id']}}?app_id={{$app_id}}" onclick="return confirm('是否确认删除');">删除</a> 
			    	</td>
			    </tr>
			{{/loop}}			    		
    	{{/if}}
    {{/loop}}
    

	</tbody></table>
    
